This software and accompanying documentation is copyright (c) microEngineering Labs, Inc. and may only be used by owners of the microEngineering Labs, Inc. EPIC Programmer. Please contact microEngineering Labs, Inc. to license this software. Contact information is listed at the end of this file.
Please see the file README.TXT for additional on the EPIC Plus Programmer. For the latest information, go to the microEngineering Labs, Inc. web site.
The EPIC Plus Programmer is an inexpensive microcontroller programmer that will program most PICmicro microcontrollers (MCUs). Most 8-, 14- and 18-pin PICmicro MCUs may be programmed in the socket on the EPIC Plus Programmer. Optional adapters are available to program 20-, 28- and 40-pin DIP PICmicro MCUs, as well as PICmicro MCUs in surface-mount and PLCC packages. It will not program the base-line PIC16C5x parts or the high-end PIC17C4x parts. See the file README.TXT for current device support.
The EPIC Plus Programmer can be powered with two 9-volt batteries or an optional AC adapter. A 16VDC, 500ma AC adapter is recommended. A suitable AC adapter is available from us.
The EPIC Plus Programmer connects to a PC compatible parallel printer port and includes an assembler and programming software. It is available either assembled or as a bare board with diskette.
The EPIC Plus Programmer files are compressed into a self-extracting file on the disk. They must be uncompressed before use.
To uncompress the files, first create a directory on your hard drive called EPIC, or another name of your choosing by typing:
c:\
md epic
at the DOS prompt.
Change to this directory:
cd epic
Assuming the distribution diskette is in drive a:, uncompress the files into the EPIC subdirectory:
a:\epicxxx -d
where epicxxx is the name of the self-extracting file on the diskette. Don't forget the -d option on the end of the command. This ensures that the proper subdirectories within EPIC are created.
Alternatively, INSTALL.BAT can be run to perform similar steps. If the EPIC directory already exists, you will get an error message and the installation will continue.
Make sure there are no PICmicro MCUs installed in the EPIC programming socket or any connected adapter's socket until the programming software is executed and the LED is off. Also be sure that the EPIC Plus Programmer is placed on an insulated surface to prevent the shorting out of traces on the bottom.
Connect the EPIC Plus Programmer to a PC compatible parallel printer port using a 25-pin male to 25-pin female printer extension cable. The EPIC Plus Programmer uses pins 2-6, 10, and 19-25. A serial cable may not have all of the necessary connections so be sure to use a printer extension cable. Do not use gender changers or switch boxes. A suitable cable is available from us.
Make sure the programmer is connected to a parallel printer port. Connection to a serial port or SCSI port, which have similar connectors, may result in damage to the port or to the programmer.
If you are powering the EPIC Plus Programmer with the optional AC adapter, plug it into the power connector on the programmer and then into a wall outlet. The AC adapter should provide approximately 16VDC at 500ma. When using an AC adapter to power the programmer, the state of the "Batt ON" jumper does not matter.
If you are powering the EPIC Plus Programmer with two 9-volt batteries, plug each battery onto the battery snaps. Connect the 2-pin shorting jumper to the 2-pin "Batt ON" posts. It is a good idea to check the battery voltage from time to time or if there seems to be difficulty programming parts.
WARNING: Do not connect a battery across the center snaps. Doing so shorts out the battery and may cause it to explode.
Note: the LED may be lit at this point. This is no cause for alarm. It should go out when the EPIC programming software is run. Do not insert or remove a PICmicro MCU when the LED is on.
The EPIC Plus Programmer should now be powered up and ready to program PICmicro MCUs.
The next task is simply to write your program using any text editor, such as DOS EDIT or Windows NOTEPAD, and assemble it using the assembler, PM, included on the disk, or MPASM (or MPLAB), available from Microchip. Instructions for the use of PM are on the included disk.
Once your program assembles properly, the generated .HEX file may be programmed into a PICmicro MCU using the EPIC programming software. Three versions of the EPIC software are included: two versions for DOS (one command line and one graphical) and one for Windows 95/98/ME/NT/2000/XP. If you choose the graphical DOS version, it should be used in a straight DOS session or from a full-screen DOS window in Windows 95/98 or OS/2. (Running the graphical DOS version of EPIC under Windows is discouraged. Windows (all varieties) alters the system timing and plays with the ports when you're not looking, which may cause programming errors.)
The Windows 95/98/ME/NT/2000/XP version should, of course, be run under Windows 95, 98, ME, NT, 2000 or XP. The Windows and command line DOS versions are more up-to-date than the graphical DOS version and are able to program more types of PICmicro MCUs. See the file README.TXT for a complete list of the devices supported by each EPIC version.
Start the DOS version of the EPIC software by typing "epicdos" at the DOS command prompt in the directory you created previously. The EPIC software will take a look around to find where the EPIC Plus Programmer is attached and get it ready to program a PICmicro MCU. If the EPIC Programmer is not found, check all of the above connections and verify there is not a PICmicro MCU installed in the programmer or any connected adapter.
Once the programming screen is displayed, select the device type you wish to program. For PIC16C8x or PIC16F8x parts, select 8x. For the PIC14C000, PIC16C55x, 6x, 7x, or 9x parts, select 6x/7x/9x. For PIC12C5xx parts, select 12C50x. See the file README.TXT for a complete list of the devices supported by EPIC for DOS.
Enter 'Alt-O' (or click Open with the mouse) to open your assembled object (.HEX) file. Double-click on the appropriate file to load it. Once the file has been loaded, make sure the proper device characteristics are selected. See the Microchip data books for information on device configuration.
Caution: Be sure that Code Protect is set to OFF before programming a windowed (JW) PICmicro MCU. You may not be able to erase a windowed part that has been code protected.
Insert a PICmicro MCU into the EPIC Plus Programmer or connected adapter socket. The end of the PICmicro MCU with the notch should be all the way at the Pin 1 end of the socket, away from the battery connectors. Press 'Alt-P' (or click Program with the mouse) to program the PICmicro MCU.
Before programming, the EPIC software does a blank check to ensure that the part is erased. PIC12Cxxx parts are not completely blank from the factory. They contain a calibration value in the last location. Simply tell EPIC that it is OK to program them anyway when it finds they are not blank. If the PICmicro MCU is a 16F84 or another EEPROM or flash part, it is usually not necessary to erase it before programming.
Typing "epicdos /?" at the DOS command prompt will display a list of available options for the EPIC software. For additional information on the EPIC Plus Programmer, please see the README file on the included diskette.
Start the Windows 95/98/ME/NT/2000/XP version of the EPIC software by navigating using Explorer to the EPIC directory and double-clicking on EPICWin. Alternatively, you can create a shortcut to EPIC on your desktop and double-click it. The EPIC software will take a look around to find where the EPIC Plus Programmer is attached and get it ready to program a PICmicro MCU. If the EPIC Programmer is not found, check all of the above connections and verify there is not a PICmicro MCU installed in the programmer or any connected adapter.
The file EPIC.INI must be in the same directory EPICWIN.EXE resides in and the EPIC directory should be in your path so that Windows can find the device drivers.
Once the programming bar is displayed, select the device type you wish to program using the drop-down device selector box to the right of the buttons.
Click the Open button or File|Open with the mouse to open your assembled object (.HEX) file. Double-click on the appropriate file to load it. Once the file has been loaded, make sure the proper device characteristics are selected under the Options menu. See the Microchip data books for information on device configuration.
Caution: Be sure that Code Protect is set to OFF before programming a windowed (JW) PICmicro MCU. You may not be able to erase a windowed part that has been code protected.
Insert a PICmicro MCU into the EPIC Plus Programmer or connected adapter socket. The end of the PICmicro MCU with the notch should be all the way at the Pin 1 end of the socket, away from the battery connectors. Click the Program button or Run|Program with the mouse to program the PICmicro MCU.
Before programming, the EPIC software optionally does a blank check to ensure that the part is erased. If the PICmicro MCU is a 16F84 or another EEPROM or flash part, it is usually not necessary to erase it before programming. PIC16F7x and PIC18Fxxx devices do require erasing each time before the MCU may be reprogrammed.
The current setup is saved to the file EPICCFG.INI when you exit EPICWin. It is reloaded the next time EPICWin is started.
The Open speed button opens a .HEX file for programming. The name of an open file appears in the EPICWin title bar. Previous configuration information will not be altered if Options|Update Configuration is not checked.
The Save speed button will save the current code, data, ID and configuration information to the currently open file. If no file has been previously selected, it will prompt for a filename.
The Program speed button will program the current code, data, ID and configuration into the selected device. It will optionally load the latest version of the .HEX file before programming. The device will be checked to ensure it is blank before programming, unless Options|Skip Blank Check is checked.
The Verify speed button will compare the current code, data, ID and configuration to the programmed device. If the information does not match, an error message is displayed. A verify is also done as the device is being programmed. A code protected device cannot be verified.
The Read speed button will read the current code, data, ID and configuration from the selected device. The configuration information will not be read if Options|Update Configuration is not checked.
The Blank Check speed button will read the code space to ensure a device is blank. It will not check the data space, ID, configuration or the oscillator calibration word programmed by the factory into some devices.
The Erase speed button will erase EEPROM or flash electrically erasable devices. It is grayed out for devices that cannot be electrically erased.
The Device box allows selection of the device to be programmed. Click the down arrow to the right of the box to drop down a list of supported devices, then click on the device. This device information, including the default device that is selected on start-up, is contained in the file EPIC.INI. This file must be in the same directory as EPICWIN.EXE. The
device should be selected before a .HEX file is opened to ensure the configuration information is properly interpreted. Devices with parenthesis after them indicate that they will program either the base version of the part, or the version contained within the parenthesis. For example, selecting the device listed as PIC16F84(A) means that either the PIC16F84 or the PIC16F84A may be programmed.
All of the speed buttons, along with many other settings, are also available using the drop-down menus.
File|New clears the EPICWin code, data and ID information. If Options|Update Configuration is checked, the configuration information will also be cleared.
File|Open opens a .HEX file for programming. The name of an open file appears in the EPICWin title bar. Previous configuration information will not be altered if Options|Update Configuration is not checked.
File|Save saves the current code, data, ID and configuration information to the currently open file. If no file has been previously selected, it will prompt for a filename.
File|Save As saves the current code, data, ID and configuration information after prompting for a new filename.
File|EPIC Port will display the parallel printer port the EPIC Programmer was found on, if Auto is checked. If Auto is not checked, the printer port can be selected manually.
File|EPIC Port|Auto allows automatic detection of the parallel printer port the EPIC Programmer is connected to, if checked. If Auto is not checked, the printer port can be selected manually.
File|Exit exits the program.
View|Code displays the code window. This will show the open .HEX file or recently read code information in hexadecimal or ASCII.
View|Configuration displays the device configuration fuse window. See the Microchip data book for information on the configuration fuses. Additional configuration fuses for the PIC17C7xx and PIC18Xxxx devices must be set from the drop-down Configuration menu.
View|Data displays the data window. This will show the open .HEX file or recently read data information in hexadecimal or ASCII. Only devices with on-chip EEPROM data space will read and program this data.
View|ID displays the ID window. This will show the open .HEX file or recently read code information in hexadecimal or ASCII.
View|Serial Number displays a window that allows the serial number to be set and programmed into the device. The serial number is stored in the code space at the specified location, overwriting any code that may already be there, and will be incremented by the Increment By value after each successful programming.
View|Count displays a window showing the number of programming attempts and successes. The count is reset when the software is started, a file is opened, a device is read or the device type is changed.
View|Close All Windows closes any open configuration, code, data, ID or count window.
View|Stay On Top causes the EPICWin bar to float on top of any other windows when checked.
Run|Program will program the current code, data, ID and configuration into the selected device. It will optionally load the latest version of the .HEX file before programming. The device will be checked to ensure it is blank before programming, unless Options|Skip Blank Check is checked.
Run|Verify will compare the current code, data, ID and configuration to the programmed device. If the information does not match, an error message is displayed. A verify is also done as the device is being programmed. A code protected device cannot be verified.
Run|Read will read the current code, data, ID and configuration from the selected device. The configuration information will not be read if Options|Update Configuration is not checked.
Run|Blank Check will read the code space to ensure a device is blank. It will not check the data space, ID, configuration or the oscillator calibration word programmed by the factory into some devices.
Run|Erase will erase EEPROM or flash electrically erasable devices. It is grayed out for devices that cannot be electrically erased.
The configuration fuses are unique to each particular PICmicro MCU. See the Microchip data sheet for the particular device for specific information on each of the configuration fuses.
Configuration|Oscillator allows setting the device's oscillator type. Options that are not available for a particular device are grayed out.
Configuration|Code Protect allows setting the device's code protection fuses. Be careful to never code protect a windowed (JW) device. Options that are not available for a particular device are grayed out.
Configuration|Watchdog Timer Postscaler allows setting the device's Watchdog Timer Postscaler values for 17C7xx and 18Cxxx devices. Options that are not available for a particular device are grayed out.
Configuration|Brown-out Voltage allows setting the device's Brown-out Reset Voltage. Options that are not available for a particular device are grayed out.
Configuration|Watchdog Timer Enable allows setting the device's Watchdog Timer state. Options that are not available for a particular device are grayed out.
Configuration|Power-up Timer Enable allows setting the device's Power-up Timer state. Options that are not available for a particular device are grayed out.
Configuration|Brown-out Reset Enable allows setting the device's Brown-out Reset state. Options that are not available for a particular device are grayed out.
Configuration|Master Clear Reset Enable allows setting the device's Master Clear Reset pin function state. Options that are not available for a particular device are grayed out.
Configuration|Memory Parity Error Enable allows setting the device's Memory Parity Error state. Options that are not available for a particular device are grayed out.
Configuration|Low-Voltage Programming Enable allows setting the device's Low-Voltage Programming state. Options that are not available for a particular device are grayed out.
Configuration|Flash Program Write Enable allows setting the device's Flash Program Write state. Options that are not available for a particular device are grayed out.
Configuration|In-Circuit Debugger Enable allows setting the device's In-Circuit Debugger state. Options that are not available for a particular device are grayed out.
Configuration|OscSys Clock Switch Enable allows setting the device's Oscillator System Clock Switch state. Options that are not available for a particular device are grayed out.
Configuration|CCP2 Multiplexed With RC2 allows setting the device's CCP2 Multiplex state. Options that are not available for a particular device are grayed out.
Configuration|Stack Reset Enable allows setting the device's Stack Reset state. Options that are not available for a particular device are grayed out.
Configuration|External Data Bus Wait Enable allows setting a PIC18Fxxx device's external address/data bus wait selections in the MEMCON register. Options that are not available for a particular device are grayed out.
Configuration|External Data Bus Width allows setting a PIC18Cxxx device's external address/data bus width. Options that are not available for a particular device are grayed out.
Configuration|Mode allows setting a PIC17C7xx or PIC18Fxxx device's microprocessor/microcontroller mode. Options that are not available for a particular device are grayed out.
Configuration|Memory Size (Words) allows viewing and setting the device's memory size, in words. It is automatically set when a device is chosen.
Options|Program/Verify Code allows the device's code space to be programmed and verified when checked. If it is not checked, the device's code space will not be programmed or verified. It will always be read and blank checked, regardless.
Options|Program/Verify Configuration allows the device's configuration fuses to be programmed and verified when checked. If it is not checked, the device's configuration fuses will not be programmed or verified.
Options|Program/Verify Data allows the device's data space, if any, to be programmed and verified when checked. If it is not checked, the device's data space will not be programmed or verified. It will always be read, regardless.
Options|Program/Verify ID allows the device's ID to be programmed and verified when checked. If it is not checked, the device's ID will not be programmed or verified. It will always be read, regardless.
Options|Program/Verify Oscillator Calibration allows the device's oscillator calibration factor location to be programmed and verified when checked. If it is not checked, the device's oscillator calibration factor location will not be programmed or verified. It will always be read, regardless.
Options|Program Serial Number allows a serial number to be programmed into the device when checked. If it is not checked, the serial number will not be programmed. As the serial number is programmed into the code space, Program Code must also be checked to program the serial number. Do not check this option unless you have verified the serial number and code location in the serial number window and wish to serialize the device.
Options|Update Configuration, when checked, will cause the configuration fuse settings to be updated when opening a file or reading a device. If it is not checked, the configuration fuse settings will not be changed.
Options|Reread File Before Programming, when checked, will cause the latest version of the .HEX file to be loaded before the device is programmed. The configuration fuse settings will also be updated, if Options|Update Configuration is checked. This will override the current settings.
Options|Erase Before Programming, when checked, will cause the device to be erased before it is programmed.
Options|Verify After Programming, when checked, will cause the device to be verified as a separate step after programming.
Options|Disable Completion Messages will prevent the displaying of operation complete messages at the end of programming, verifying and erasing a device.
Options|Skip Blank Check will prevent blank checking a device before it is programmed when checked.
Help|Help opens the default browser and displays the HTML help file.
Help|Readme opens the default text editor and displays the README file.
Help|About... displays the program version number and copyright.
Several optional parameters may be passed to the EPICWin program via the command line:
EPICWin {switch}, {filename}
The available command line switches are:
For example:
EPICWin /DPIC16F877 BLINK
would tell EPICWin to select the PIC16F877 as the device and open the file BLINK.HEX.
The EPIC Plus Programmer may be used for in-circuit serial programming of serial programmable PICmicro MCUs through the 10-pin expansion header J3. Vpp, RB6, RB7 and ground should be connected as in the following diagram. Any additional connections to /MCLR, RB6 and RB7 should be designed as to not interfere with in-circuit programming. The cable connecting the EPIC 10-pin header to the target board should be less that 6 inches long. The drawing shows the pinouts and connections to the 18-pin PIC16F84. For other PICmicro MCUs, use their corresponding pin connections.
Note: +5 volts should be supplied to the PICmicro MCU by the target system. The +5 volt and Vdd lines from the EPIC Plus Programmer header are not intended to power external circuits.
Note for PIC16F62x: PORTB, pin 4 should be connected to ground to prevent interference from the Low Voltage Programming pin.
Note for PIC16F87x: PORTB, pin 3 should be connected to ground to prevent interference from the Low Voltage Programming pin.
Note for PIC17C7xx: These devices may also be programmed in-circuit. However, different pins are required than shown above. See the Microchip programming spec on these devices for more information.
Note for PIC18Fxxx: PORTB, pin 5 should be connected to ground to prevent interference from the Low Voltage Programming pin.
In general, the EPIC Programmer is easy to use without difficulty. However, if there is a problem, the following may help.
The most common cause of programming problems is low power supply voltage. We highly recommend the use of an AC Adapter. Batteries become depleted very quickly, causing program errors ("Code Programming Error at 0000").
The adapter that we supply for use with the EPIC outputs 16VDC at 500mA. You may substitute an adapter if it meets the voltage and current requirements of the EPIC Programmer. Your adapter should output at least 13VAC or 16VDC at 300mA. The AC adapter connection on the EPIC is not polarity sensitive.
The next most common problem is incorrect option settings in the EPICWin software. This software has a large number of configuration and option settings that can be a bit confusing. This EPIC help file includes an explanation of the EPICWin Menus.
Some common symptoms and causes are:
"Code Programming Error at... "
"Device Not Blank..."
"EPIC Programmer Not Found"
"Unable to load driver..."
"Unable to load driver PICLPTNT.SYS"
To remove the NT/2000/XP driver: ntinst /remove
To install the NT/2000/XP driver: ntinst /install
Most of the following parts are available from Radio Shack. Any additional parts may be acquired from Jameco Electronics or JDR Microdevices. The Radio Shack part number is listed for reference.
Label Description Radio Shack Part No. R1 240 (270) ohm 1/4W resistor 271-1314 R2 not used R3,4,6,7,12 1K 1/4W resistor 271-1321 R5,8,10 10K resistor 1/4W resistor 271-1335 R9,11 100 ohm 1/4W resistor 271-1311 VR1 5K (4.7K) PCB mount trimmer 271-281 C1* 100uf 50V radial electrolytic capacitor 272-1044 C2 10uf 25V radial electrolytic capacitor 272-1025 C3 .1uf 50V monolythic capacitor 272-109 BR1* 1A 100PIV diode bridge 276-1152 LED1 red LED 276-041 Q1,2 2N3906 (MPS2907) PNP transistor 276-2023 REG1 7805T 5-volt regulator 276-1770 REG2 LM317T variable regulator 276-1778 U1 7407 open collector hex buffer IC J1 25-pin MALE DB25P connector J2* 2.1mm DC power jack J3 10-pin (5x2) header B1,2 9-volt battery snaps 270-325 14-pin IC socket 276-1999 18-pin IC (or ZIF) socket 276-1992 S1 2-pin Battery ON header 2-pin shorting jumper * C1, BR1 and J2 are not necessary for battery-only operation.
1. Solder in resistors R1 and R3-R12.
2. Solder in sockets for U1 and U2 if U2 is not a ZIF socket.
3. Solder in trimmer VR1.
4. Solder in transistors Q1 and Q2.
5. Solder in capacitors C1-3. Note the polarity of C1 and C2. C1 is not necessary for battery-only operation.
6. Solder in bridge BR1 and J2 if AC operation is desired.
7. Solder in MALE DB25P connector J1.
8. Solder in LED1. Be sure the flat side of the LED is away from connector J1.
9. Solder in the 10-pin header J3.
10. Solder in Battery ON 2-pin header. Place the shorting jumper across the header before soldering to prevent the pins from moving when heated. A piece of wire may be soldered into the header holes if the Battery ON jumper is not desired. In that case the batteries may be connected and disconnected to turn the programmer on and off.
11. Solder in the 9-volt battery snaps B1 and B2. Make sure the polarity noted on the board matches the polarity of the 9-volt battery terminals. Double check this operation as getting one or both backwards is not a good thing.
12. If U2 is a ZIF socket, solder it in now.
13. Solder REG1 and REG2 into place. Be sure the larger heat sink side is away from connector J1.
Before proceeding, check the almost completed board for the proper voltages.
Adjust trimmer VR1 to about the middle of its range.
Connect an AC adapter or the two 9-volt batteries and Battery ON jumper. At this point neither regulator should get hot. If either one does, immediately disconnect power and check for improper battery connector polarity or regulators in backwards.
Measure the output of the variable regulator REG2 and adjust trimmer VR1 to give about 13.5 volts. The easiest place to measure the voltage is between the heatsink tab of the 7805T REG1 (ground) and the end of R1 furthest from the battery connectors.
Measure the output of the 7805T REG1 for 5 volts. The best place to measure is between pin 7 (ground) and pin 14 of the 7407 U1.
If the voltages are not correct, check the polarity of the battery connections and the regulators. Also check to see that all of the other components are properly soldered in place.
14. Once all of the voltages check out, install U1 7407 in the 14-pin socket. Make sure the end with the notch (pin 1) is away from the battery connectors.